package com.abu.edums.controller;

import com.abu.utils.Resp;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/eduservice/teacher")
public class LoginController {

    @PostMapping("login")
    public Resp login() {
        return Resp.ok().data("token", "admin");
    }

    @GetMapping("info")
    public Resp info() {
        return Resp.ok().data("roles", "[admin]").data("name", "admin").data("avatar", "https://abu-edu.oss-cn-beijing.aliyuncs.com/IMG_20200619_191145.png");
    }

}
